package com.xls.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.xls.domain.Orderinfo;
import com.xls.service.OrderinfoService;
import com.xls.mapper.OrderinfoMapper;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @author 韶光善良君
* @description 针对表【orderinfo】的数据库操作Service实现
* @createDate 2024-04-09 20:52:25
*/
@Service
public class OrderinfoServiceImpl extends ServiceImpl<OrderinfoMapper, Orderinfo>
    implements OrderinfoService{

    @Override
    public List<Orderinfo> getOrderByUserId(Integer userId) {
        LambdaQueryWrapper<Orderinfo> wrapper = new LambdaQueryWrapper<>();
        wrapper.eq(Orderinfo::getUserid,userId);
        return this.list(wrapper);
    }
}




